import { requestPort, httpUpload } from '@/utils/request.js';


export default {
  //获取服务分类
  getServiceCate: function (params) {
    return requestPort({
      url: '/api/service/getallcate',
      method: 'POST',
      params: params
    })
  },

  getServiceCateChild: function (params) {
    return requestPort({
      url: '/api/service/getCate',
      method: 'POST',
      params: params
    })
  },

  getShopList: function (params) {
    return requestPort({
      url: '/api/service/shop_list',
      method: 'POST',
      params: params
    })
  },

  getServiceList: function (params) {
    return requestPort({
      url: '/api/service/getServiceList',
      method: 'POST',
      params: params
    })
  },

  //获取需求列表数据
  getDemandList: function (params) {
    return requestPort({
      url: '/api/service/demandList',
      method: 'POST',
      params: params
    });
  },

  //获取最新需求列表数据
  getDemandNewList: function (params) {
    return requestPort({
      url: '/api/service/user_index',
      method: 'POST',
      params: params
    });
  },

  //上传图片
  uploadImg: function (params) {
    return httpUpload({
      url: '/api/common/upload',
      method: 'POST',
      params: params
    });
  },

  //成为服务商
  becomeService: function (params) {
    return requestPort({
      url: '/api/service/apply',
      method: 'POST',
      params: params
    });
  },

  //请求服务类名
  getServiceCate: function (params) {
    return requestPort({
      url: '/api/service/getallcate',
      method: 'POST',
      params: params
    });
  },

  //获取订单状态展示数据
  orderStatus: function (params) {
    return requestPort({
      url: '/api/service/user_index',
      method: 'POST',
      params: params
    });
  },

  //获取服务商保证金
  getDeposit: function (params) {
    return requestPort({
      url: '/api/service/getall_cost',
      method: 'POST',
      params: params
    });
  },

  //生成服务商订单信息
  getPayData: function (params) {
    return requestPort({
      url: '/api/service/getPayData',
      method: 'POST',
      params: params
    });
  },

  //请求个人信息
  getUserInfo: function (params) {
    return requestPort({
      url: '/api/user/getUserInfo',
      method: 'POST',
      params: params
    });
  },

  //企服聊天记录过滤接口，获取问答列表
  filtration: function (params) {
    return requestPort({
      url: '/api/Jianghunew/get_major_list_id',
      method: 'POST',
      params: params
    })
  },


  //获取用户信息
  getZeGoToken_chat: function (params) {
    return requestPort({
      url: '/api/Jianghunew/getzegotoken',
      method: 'POST',
      params: params
    });
  },

  //获取我的收藏
  getMyCollect: function (params) {
    return requestPort({
      url: '/api/user/getMyCollect',
      method: 'POST',
      params: params
    });
  },

  //收藏
  setCollect: function (params) {
    return requestPort({
      url: '/api/service/setCollect',
      method: 'POST',
      params: params
    });
  },

  LogInDemoMain: function (params) {
    return requestPort({
      url: '/api/Logindemo/main',
      method: 'POST',
      params: params
    });
  }
}